Fix test failures and add comprehensive improvements (v1.4.0)#1
Merged
subhobhai943 merged 9 commits intomainfrom Nov 12, 2025
Merged
Fix test failures and add comprehensive improvements (v1.4.0)#1subhobhai943 merged 9 commits intomainfrom
subhobhai943 merged 9 commits intomainfrom
Conversation
Owner
Author
🎉 All Fixes and Improvements Complete!I've successfully fixed all the test failures and added comprehensive improvements to your pyandroid-dev library. Here's what was done: 🐞 Critical Bug Fixes1. Test Workflow - FIXED ✅
2. Backend Import Errors - FIXED ✅
3. Activity Lifecycle - FIXED ✅
🆕 New Features Added
📊 Test Suite Improvements
📝 Documentation Added
🛠️ Files Modified
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR fixes all test failures and adds significant improvements to the pyandroid-dev library for version 1.4.0.
Critical Fixes
✅ Test Workflow Fixed
--cov-report=xmland--cov-report=termflags✅ Backend Import Error Handling
✅ Activity Lifecycle Validation
InvalidStateErrorfor invalid operationsNew Features
🎯 Custom Exception Classes
PyAndroidError- Base exception classActivityNotFoundError- Activity not registeredInvalidStateError- Invalid state transitions🎯 Enhanced Type Hints
🎯 Activity Extras
activity.extrasdictionary🎯 Intent Improvements
has_extra(key)- Check if extra existsget_all_extras()- Get all extras as dictionary🎯 View Management
remove_view()method to Activity classCode Quality Improvements
📝 Documentation
🧪 Test Suite Enhancements
conftest.pyfor shared configuration🔧 Better Error Messages
Configuration Updates
Breaking Changes
InvalidStateErrorTesting
All tests now pass:
Files Changed
.github/workflows/tests.yml- Fixed coverage generationpyandroid/backend/__init__.py- Graceful import error handlingpyandroid/core.py- Major improvements (exceptions, validation, type hints)tests/test_core.py- Comprehensive test improvementstests/test_ui.py- Additional UI component teststests/conftest.py- New shared test configurationpyproject.toml- Updated metadata and Python versionIMPROVEMENTS.md- Full documentation of changesDocumentation
See IMPROVEMENTS.md for detailed documentation of all changes, migration guide, and examples.
Checklist
Next Steps
After merging:
Ready to merge! This PR significantly improves the library's reliability, maintainability, and developer experience.